In a standard internet protocol virtual server (IPVS) environment, a virtual internet protocol (IP) address is shared by real request handling servers and an IPVS load balancer. All incoming IP packets arrive at the load balancer, which acts as a router to direct the IP packets to the appropriate server. The load balancer manages the connections to individual servers, to balance the load among the group of servers.
Connection oriented protocols, such as transmission control protocol (TCP), rely on the endpoints (also referred to as end nodes) of the connection to be active and connected for the duration of the connection. In TCP, there are certain mechanisms that may be used to ensure that the endpoints remain active during a connection.
In order to reduce the overhead of opening and closing TCP sockets, and to reduce the latency of performing TCP handshakes, persistent connections are often used. However, use of a persistent connection may result in resources (e.g., memory and other operating system resources) being locked to keep the persistent connection open even when there is no data being sent over the connection, making the resources unavailable for other clients. Further, a persistent connection presents difficulties for load rebalancing in a group of servers because the connection cannot be rerouted without breaking the persistent connection. If an active persistent connection is broken to allow for load rebalancing, data may be lost during this process and the client may be required to participate in another handshake process to re-establish the connection. This may be undesirable.